package ro.upt.ac.cstaicu.analyze;

public class FaultLocalizationEntity implements Comparable<FaultLocalizationEntity> {

	public final Entity entity;
	public double souspiciousness;
	
	public FaultLocalizationEntity(Entity entity, double souspicousness) {
		this.entity = entity;
		this.souspiciousness = souspicousness;
	}
	
	public int compareTo(FaultLocalizationEntity o) {
		return (int)(100 * (o.souspiciousness - souspiciousness));
	}
	
	public String toString() {
		return souspiciousness + " " + entity;
	}
	
}
